package com.aos.erp.message.rest;

//
//@Slf4j
//@Api(tags = {"UI接口：消息模板接口"})
//@RestController
//@RequestMapping("/api/message/template")
//public class RestMessageTemplateController {
//
//    @Autowired
//    MessageTemplateService messageTemplateService;
//
//    @ApiOperation(value = "保存消息模板")
//    @ApiImplicitParams({
//            @ApiImplicitParam(name = "mtTitle", value = "模板标题(100字符内)", required = true, dataType = "String"),
//            @ApiImplicitParam(name = "pushTypeList", value = "推送方式数组[{mtContent:'消息模板(1000字符内，APP、短信推送需要)',mtWxTemplateId:'微信模板ID,微信公众号、微信小程序推送需要',mtUrl:'跳转链接,微信公众号、微信小程序推送需要，其中小程序仅限小程序内的页面;可不传,点击后无跳转',pushType:推送方式(app:APP；wx_public:微信公众号；wx_applet:微信小程序；sms:短信),pushParam:[{mtpId:参数项ID,mtpItem:'参数项', mtpDesc:'参数项描述'}] }]", required = true, dataType = "List"),
//            @ApiImplicitParam(name = "mtDriverSchoolList", value = "模板下发驾校数组[{dsId:0,dsCode:'驾校编号',dsName:'驾校名称'}]", required = true, dataType = "List"),
//    })
//    @PostMapping("/add")
//    public ResultEntity addTemplate(@ApiParam("入参") @RequestBody MessageTemplateVo params, String currentUserId) throws Exception{
//
//        params.setOptUser("张老师");
//        messageTemplateService.saveTemplate(params);
//        return ResultEntity.success("新增成功");
//    }
//
//    @ApiOperation(value = "编辑消息模板")
//    @ApiImplicitParams({
//            @ApiImplicitParam(name = "id", value = "模板ID", required = true, dataType = "Long", paramType = "Query"),
//            @ApiImplicitParam(name = "mtTitle", value = "模板标题(100字符内)", required = true, dataType = "String"),
//            @ApiImplicitParam(name = "pushTypeList", value = "推送方式数组[{mtContent:'消息模板(1000字符内，APP、短信推送需要)',mtWxTemplateId:'微信模板ID,微信公众号、微信小程序推送需要',mtUrl:'跳转链接,微信公众号、微信小程序推送需要，其中小程序仅限小程序内的页面;可不传,点击后无跳转',pushType:推送方式(app:APP；wx_public:微信公众号；wx_applet:微信小程序；sms:短信)}]", required = true, dataType = "List"),
//            @ApiImplicitParam(name = "mtDriverSchoolList", value = "模板下发驾校数组[{dsId:0,dsCode:'驾校编号',dsName:'驾校名称'}]", required = true, dataType = "List"),
//    })
//    @PostMapping("/update")
//    public ResultEntity updateTemplate(@ApiParam(value = "入参") @RequestBody MessageTemplateVo params, String currentUserId) throws Exception{
//
//        params.setOptUser("张老师");
//        messageTemplateService.updateTemplate(params);
//        return ResultEntity.success("修改成功");
//    }
//
//    @ApiOperation(value = "删除消息模板")
//    @ApiImplicitParams({
//            @ApiImplicitParam(name = "ids", value = "模板ID", required = true, dataType = "Long", paramType = "Query")
//    })
//    @GetMapping("/delete")
//    public ResultEntity deleteTemplate(String ids) throws Exception{
//        messageTemplateService.deleteTemplate(ids);
//        return ResultEntity.success("删除成功");
//    }
//
//    @ApiOperation(value = "分页查询消息模板")
//    @ApiImplicitParams({
//            @ApiImplicitParam(name = "pageIndex", value = "当前页", required = true, dataType = "Integer", defaultValue = "1", paramType = "Query"),
//            @ApiImplicitParam(name = "pageSize", value = "每页大小", required = true, dataType = "Integer", defaultValue = "20", paramType = "Query"),
//            @ApiImplicitParam(name = "mtCode", value = "模板编号", dataType = "String", paramType = "Query"),
//            @ApiImplicitParam(name = "mtTitle", value = "模板标题", dataType = "String", paramType = "Query"),
//            @ApiImplicitParam(name = "pushType", value = "推送方式(app:APP；wx_public:微信公众号；wx_applet:微信小程序；sms:短信)", dataType = "PushType", paramType = "Query"),
//            @ApiImplicitParam(name = "fromTime", value = "开始时间", dataType = "String", paramType = "Query"),
//            @ApiImplicitParam(name = "toTime", value = "截止时间", dataType = "String", paramType = "Query")
//    })
//    @GetMapping("/list")
//    public ResultEntity<PageBean<MessageTemplateItemDTO>> listTemplate(MTConditionVo params) {
//        return ResultEntity.success(messageTemplateService.findByPage(params));
//    }
//
//    @ApiOperation(value = "查看模板详情")
//    @ApiImplicitParams({
//            @ApiImplicitParam(name = "dataId", value = "模板ID", required = true, dataType = "Long", paramType = "Query")
//    })
//    @GetMapping("/detail")
//    public ResultEntity<MessageTemplateDTO> detailNotice(Long dataId){
//        return ResultEntity.success(messageTemplateService.getTemplateDetail(dataId));
//    }
//}
